rem ********************************************************************************************
rem    You should rename this file to makeEnv.cmd (without "_" char)
rem    and change varriables according your settings
rem ********************************************************************************************

rem Default Database server
set DefaultDBServerName=MAGGIE\SQLEXPRESS

rem Default Database name
set DefaultDatabaseName=Eye_DB


rem database server (1st param)
set serverName=%1
if [%serverName%]==[] set serverName=%DefaultDBServerName%
if [%serverName%]==[""] set serverName=%DefaultDBServerName%

rem database name (2nd param)
set databaseName=%2
if [%databaseName%]==[] set databaseName=%DefaultDatabaseName%
if [%databaseName%]==[""] set databaseName=%DefaultDatabaseName%

rem *********** Configuring DB Setup User **************************
rem use current windows credentials for setup DB
set dbsetup_usecurrentwindowscredentials=true

rem if dbsetup_usecurrentwindowscredentials is false
set dbsetup_login=""
set dbsetup_password=""
rem *********** Set owner login for job ****************************
set dbjobowner_login=""
rem **************************************************************


set sql_cmd_ut=SQLCMD

set dbServerParam= -S %serverName%

if %dbsetup_usecurrentwindowscredentials%==true (set credentials=%dbServerParam% -E) else (set credentials=%dbServerParam% -U %dbsetup_login% -P %dbsetup_password%)
if %dbsetup_usecurrentwindowscredentials%==true (set bcpcredentials=%dbServerParam% -T) else (set bcpcredentials=%dbServerParam% -U %dbsetup_login% -P %dbsetup_password%)
